package com.cq.mapper;

import com.cq.pojo.Banner;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;
import org.springframework.stereotype.Repository;

import java.util.List;

/**
 * @Author: 悠久的苍穹
 * @Date: 2021/1/20 15:56
 * @Description: 广告持久层
 * @Version: 1.0
 */
@Mapper
@Repository
public interface BannerMapper {
    List<Banner> findAllBanner();

    List<Banner> findBanners(@Param("page") int page, @Param("limit") int limit);

    int getCount();

    Banner findBannerById(@Param("id") int id);

    int updateBanner(Banner banner);

    List<Banner> findAllBannerIshow();

    int addBanner(Banner banner);

    void deleteBannerById(@Param("id") int id);
}
